<template>
	<view>
		<uni-nav-bar fixed left-icon="back" title="钱包充值"></uni-nav-bar>

		<view class="ui-row-money">
			<view>充值金额</view>
			<view class="tui-flex">
				<text style="width: 10%">￥</text>
				<input class="input" type="digit" focus auto-blur v-model="actMoney" placeholder-class="placeholder"/>
			</view>
		</view>

		<view class="ui-btn">
			<button class="btn"
			        type="primary"
					:style="{background: `${!actMoney? 'rgb(140,206,99)': '#6CB041'}`} "
					@tap="fareGo()"
					:disabled="!actMoney">
					确定
			</button>
		</view>

		<!-- 登录提示 -->
		<uni-login-model></uni-login-model>
	</view>
</template>
<script>
    import uniLoginModel from '@/components/uni-login-model/uni-login-model.vue'

	export default {
		components: {
            uniLoginModel
		},
		data() {
			return {
                actMoney: null
			}
		},
		onLoad() {
		},
		methods: {
            fareGo() {
                this.$wx.miniProgram.reLaunch({
                    url: `/pages/walletPay/walletPay?actMoney=${this.actMoney}`,
                    success: function(){
                        console.log('success')
                    },
                    fail: function(err){
                    },
                    complete:function(){
                        console.log('complete');
                    }
                });
            }
		}
	}
</script>
<style lang="scss" scoped>
.ui-row-money{
	margin: 60rpx 30rpx;
	background: #ffffff;
	padding: 30rpx;
	border-radius: 20rpx;
	font-size: 32rpx;
	.tui-flex {
		padding-top: 30rpx;
		font-size: 50rpx;
		.placeholder {
			font-size: 50rpx;
			padding-left: 15rpx;
		}
		.input{
			height: 80rpx;
			flex: 1;
			font-size: 60rpx;
		}
	}
}
.ui-btn {
	margin: 30rpx;
	.btn {
		background: #6CB041;
		color: #fff;
	}
}
</style>